package net.oschina.esb.webmvc.auto.parameter;

import net.oschina.esb.webmvc.util.RequestUtil;

import javax.servlet.http.HttpServletRequest;

/**
 * @author Arvin
 * @time 2018/5/5 8:22
 */
public class ClientIpPageParameter implements PageParameter {

    @Override
    public String getName() {
        return "clientIp";
    }

    @Override
    public String getValue(HttpServletRequest request) {
        return RequestUtil.getClientIp(request);
    }
}
